package com.guoxin.thread.threadlocal;

import java.util.concurrent.Executor;

public class Resource {

    public ThreadLocal<Integer> count = ThreadLocal.withInitial(() -> 0);

    public int getNum(){
        int cc = count.get()+1;
        count.set(cc);
        return cc;
    }
}
